package NotificationIRPSystem;


/**
 * Generated from IDL interface "NotificationIRP".
 *
 * @author JacORB IDL compiler V 2.3.0, 17-Feb-2007
 * @version generated at 2013-5-20 22:07:19
 */

public abstract class NotificationIRPPOA
	extends org.omg.PortableServer.Servant
	implements org.omg.CORBA.portable.InvokeHandler, NotificationIRPSystem.NotificationIRPOperations
{
	static private final java.util.Hashtable m_opsHash = new java.util.Hashtable();
	static
	{
		m_opsHash.put ( "attach_push", new java.lang.Integer(0));
		m_opsHash.put ( "get_notification_irp_operations_profile", new java.lang.Integer(1));
		m_opsHash.put ( "attach_pull", new java.lang.Integer(2));
		m_opsHash.put ( "attach_push_b", new java.lang.Integer(3));
		m_opsHash.put ( "get_subscription_status", new java.lang.Integer(4));
		m_opsHash.put ( "change_subscription_filter", new java.lang.Integer(5));
		m_opsHash.put ( "detach", new java.lang.Integer(6));
		m_opsHash.put ( "get_notification_irp_notification_profile", new java.lang.Integer(7));
		m_opsHash.put ( "get_subscription_ids", new java.lang.Integer(8));
		m_opsHash.put ( "get_notification_irp_versions", new java.lang.Integer(9));
		m_opsHash.put ( "get_notification_categories", new java.lang.Integer(10));
	}
	private String[] ids = {"IDL:NotificationIRPSystem/NotificationIRP:1.0"};
	public NotificationIRPSystem.NotificationIRP _this()
	{
		return NotificationIRPSystem.NotificationIRPHelper.narrow(_this_object());
	}
	public NotificationIRPSystem.NotificationIRP _this(org.omg.CORBA.ORB orb)
	{
		return NotificationIRPSystem.NotificationIRPHelper.narrow(_this_object(orb));
	}
	public org.omg.CORBA.portable.OutputStream _invoke(String method, org.omg.CORBA.portable.InputStream _input, org.omg.CORBA.portable.ResponseHandler handler)
		throws org.omg.CORBA.SystemException
	{
		org.omg.CORBA.portable.OutputStream _out = null;
		// do something
		// quick lookup of operation
		java.lang.Integer opsIndex = (java.lang.Integer)m_opsHash.get ( method );
		if ( null == opsIndex )
			throw new org.omg.CORBA.BAD_OPERATION(method + " not found");
		switch ( opsIndex.intValue() )
		{
			case 0: // attach_push
			{
			try
			{
				java.lang.String _arg0=_input.read_string();
				int _arg1=_input.read_ulong();
				java.lang.String[] _arg2=ManagedGenericIRPConstDefs.VersionNumberSetHelper.read(_input);
				ManagedGenericIRPConstDefs.StringOpt _arg3=ManagedGenericIRPConstDefs.StringOptHelper.read(_input);
				_out = handler.createReply();
				_out.write_string(attach_push(_arg0,_arg1,_arg2,_arg3));
			}
			catch(NotificationIRPSystem.AlreadySubscribed _ex0)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.AlreadySubscribedHelper.write(_out, _ex0);
			}
			catch(ManagedGenericIRPSystem.InvalidParameter _ex1)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.InvalidParameterHelper.write(_out, _ex1);
			}
			catch(NotificationIRPSystem.Attach _ex2)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.AttachHelper.write(_out, _ex2);
			}
			catch(NotificationIRPSystem.AtLeastOneNotificationCategoryNotSupported _ex3)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.AtLeastOneNotificationCategoryNotSupportedHelper.write(_out, _ex3);
			}
			catch(ManagedGenericIRPSystem.ParameterNotSupported _ex4)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.ParameterNotSupportedHelper.write(_out, _ex4);
			}
				break;
			}
			case 1: // get_notification_irp_operations_profile
			{
			try
			{
				java.lang.String _arg0=_input.read_string();
				_out = handler.createReply();
				ManagedGenericIRPConstDefs.MethodListHelper.write(_out,get_notification_irp_operations_profile(_arg0));
			}
			catch(ManagedGenericIRPSystem.InvalidParameter _ex0)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.InvalidParameterHelper.write(_out, _ex0);
			}
			catch(ManagedGenericIRPSystem.OperationNotSupported _ex1)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.OperationNotSupportedHelper.write(_out, _ex1);
			}
			catch(NotificationIRPSystem.GetNotificationIRPOperationsProfile _ex2)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.GetNotificationIRPOperationsProfileHelper.write(_out, _ex2);
			}
				break;
			}
			case 2: // attach_pull
			{
			try
			{
				java.lang.String _arg0=_input.read_string();
				int _arg1=_input.read_ulong();
				java.lang.String[] _arg2=ManagedGenericIRPConstDefs.VersionNumberSetHelper.read(_input);
				ManagedGenericIRPConstDefs.StringOpt _arg3=ManagedGenericIRPConstDefs.StringOptHelper.read(_input);
				CosNotifyChannelAdmin.SequenceProxyPullSupplierHolder _arg4= new CosNotifyChannelAdmin.SequenceProxyPullSupplierHolder();
				_out = handler.createReply();
				_out.write_string(attach_pull(_arg0,_arg1,_arg2,_arg3,_arg4));
				CosNotifyChannelAdmin.SequenceProxyPullSupplierHelper.write(_out,_arg4.value);
			}
			catch(NotificationIRPSystem.AlreadySubscribed _ex0)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.AlreadySubscribedHelper.write(_out, _ex0);
			}
			catch(ManagedGenericIRPSystem.InvalidParameter _ex1)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.InvalidParameterHelper.write(_out, _ex1);
			}
			catch(ManagedGenericIRPSystem.OperationNotSupported _ex2)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.OperationNotSupportedHelper.write(_out, _ex2);
			}
			catch(NotificationIRPSystem.Attach _ex3)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.AttachHelper.write(_out, _ex3);
			}
			catch(NotificationIRPSystem.AtLeastOneNotificationCategoryNotSupported _ex4)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.AtLeastOneNotificationCategoryNotSupportedHelper.write(_out, _ex4);
			}
			catch(ManagedGenericIRPSystem.ParameterNotSupported _ex5)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.ParameterNotSupportedHelper.write(_out, _ex5);
			}
				break;
			}
			case 3: // attach_push_b
			{
			try
			{
				java.lang.String _arg0=_input.read_string();
				int _arg1=_input.read_ulong();
				java.lang.String[] _arg2=ManagedGenericIRPConstDefs.VersionNumberSetHelper.read(_input);
				ManagedGenericIRPConstDefs.StringOpt _arg3=ManagedGenericIRPConstDefs.StringOptHelper.read(_input);
				CosNotifyChannelAdmin.SequenceProxyPushSupplierHolder _arg4= new CosNotifyChannelAdmin.SequenceProxyPushSupplierHolder();
				_out = handler.createReply();
				_out.write_string(attach_push_b(_arg0,_arg1,_arg2,_arg3,_arg4));
				CosNotifyChannelAdmin.SequenceProxyPushSupplierHelper.write(_out,_arg4.value);
			}
			catch(NotificationIRPSystem.AlreadySubscribed _ex0)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.AlreadySubscribedHelper.write(_out, _ex0);
			}
			catch(ManagedGenericIRPSystem.InvalidParameter _ex1)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.InvalidParameterHelper.write(_out, _ex1);
			}
			catch(ManagedGenericIRPSystem.OperationNotSupported _ex2)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.OperationNotSupportedHelper.write(_out, _ex2);
			}
			catch(NotificationIRPSystem.Attach _ex3)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.AttachHelper.write(_out, _ex3);
			}
			catch(NotificationIRPSystem.AtLeastOneNotificationCategoryNotSupported _ex4)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.AtLeastOneNotificationCategoryNotSupportedHelper.write(_out, _ex4);
			}
			catch(ManagedGenericIRPSystem.ParameterNotSupported _ex5)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.ParameterNotSupportedHelper.write(_out, _ex5);
			}
				break;
			}
			case 4: // get_subscription_status
			{
			try
			{
				java.lang.String _arg0=_input.read_string();
				ManagedGenericIRPConstDefs.StringOptHolder _arg1= new ManagedGenericIRPConstDefs.StringOptHolder();
				NotificationIRPConstDefs.SubscriptionStateHolder _arg2= new NotificationIRPConstDefs.SubscriptionStateHolder();
				org.omg.CORBA.IntHolder _arg3= new org.omg.CORBA.IntHolder();
				_out = handler.createReply();
				ManagedGenericIRPConstDefs.VersionNumberSetHelper.write(_out,get_subscription_status(_arg0,_arg1,_arg2,_arg3));
				ManagedGenericIRPConstDefs.StringOptHelper.write(_out,_arg1.value);
				NotificationIRPConstDefs.SubscriptionStateHelper.write(_out,_arg2.value);
				_out.write_ulong(_arg3.value);
			}
			catch(ManagedGenericIRPSystem.InvalidParameter _ex0)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.InvalidParameterHelper.write(_out, _ex0);
			}
			catch(ManagedGenericIRPSystem.OperationNotSupported _ex1)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.OperationNotSupportedHelper.write(_out, _ex1);
			}
			catch(NotificationIRPSystem.GetSubscriptionStatus _ex2)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.GetSubscriptionStatusHelper.write(_out, _ex2);
			}
				break;
			}
			case 5: // change_subscription_filter
			{
			try
			{
				java.lang.String _arg0=_input.read_string();
				java.lang.String _arg1=_input.read_string();
				_out = handler.createReply();
				change_subscription_filter(_arg0,_arg1);
			}
			catch(ManagedGenericIRPSystem.InvalidParameter _ex0)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.InvalidParameterHelper.write(_out, _ex0);
			}
			catch(ManagedGenericIRPSystem.OperationNotSupported _ex1)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.OperationNotSupportedHelper.write(_out, _ex1);
			}
			catch(NotificationIRPSystem.ChangeSubscriptionFilter _ex2)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.ChangeSubscriptionFilterHelper.write(_out, _ex2);
			}
				break;
			}
			case 6: // detach
			{
			try
			{
				java.lang.String _arg0=_input.read_string();
				java.lang.String _arg1=_input.read_string();
				_out = handler.createReply();
				detach(_arg0,_arg1);
			}
			catch(ManagedGenericIRPSystem.InvalidParameter _ex0)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.InvalidParameterHelper.write(_out, _ex0);
			}
			catch(NotificationIRPSystem.DetachException _ex1)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.DetachExceptionHelper.write(_out, _ex1);
			}
			catch(ManagedGenericIRPSystem.ParameterNotSupported _ex2)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.ParameterNotSupportedHelper.write(_out, _ex2);
			}
				break;
			}
			case 7: // get_notification_irp_notification_profile
			{
			try
			{
				java.lang.String _arg0=_input.read_string();
				_out = handler.createReply();
				ManagedGenericIRPConstDefs.MethodListHelper.write(_out,get_notification_irp_notification_profile(_arg0));
			}
			catch(NotificationIRPSystem.GetNotificationIRPNotificationProfile _ex0)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.GetNotificationIRPNotificationProfileHelper.write(_out, _ex0);
			}
			catch(ManagedGenericIRPSystem.InvalidParameter _ex1)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.InvalidParameterHelper.write(_out, _ex1);
			}
			catch(ManagedGenericIRPSystem.OperationNotSupported _ex2)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.OperationNotSupportedHelper.write(_out, _ex2);
			}
				break;
			}
			case 8: // get_subscription_ids
			{
			try
			{
				java.lang.String _arg0=_input.read_string();
				_out = handler.createReply();
				NotificationIRPConstDefs.SubscriptionIdSetHelper.write(_out,get_subscription_ids(_arg0));
			}
			catch(ManagedGenericIRPSystem.InvalidParameter _ex0)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.InvalidParameterHelper.write(_out, _ex0);
			}
			catch(ManagedGenericIRPSystem.OperationNotSupported _ex1)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.OperationNotSupportedHelper.write(_out, _ex1);
			}
			catch(NotificationIRPSystem.GetSubscriptionIds _ex2)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.GetSubscriptionIdsHelper.write(_out, _ex2);
			}
				break;
			}
			case 9: // get_notification_irp_versions
			{
			try
			{
				_out = handler.createReply();
				ManagedGenericIRPConstDefs.VersionNumberSetHelper.write(_out,get_notification_irp_versions());
			}
			catch(NotificationIRPSystem.GetNotificationIRPVersions _ex0)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.GetNotificationIRPVersionsHelper.write(_out, _ex0);
			}
				break;
			}
			case 10: // get_notification_categories
			{
			try
			{
				NotificationIRPConstDefs.NotificationTypesSetHolder _arg0= new NotificationIRPConstDefs.NotificationTypesSetHolder();
				_out = handler.createReply();
				ManagedGenericIRPConstDefs.VersionNumberSetHelper.write(_out,get_notification_categories(_arg0));
				NotificationIRPConstDefs.NotificationTypesSetHelper.write(_out,_arg0.value);
			}
			catch(NotificationIRPSystem.GetNotificationCategories _ex0)
			{
				_out = handler.createExceptionReply();
				NotificationIRPSystem.GetNotificationCategoriesHelper.write(_out, _ex0);
			}
			catch(ManagedGenericIRPSystem.OperationNotSupported _ex1)
			{
				_out = handler.createExceptionReply();
				ManagedGenericIRPSystem.OperationNotSupportedHelper.write(_out, _ex1);
			}
				break;
			}
		}
		return _out;
	}

	public String[] _all_interfaces(org.omg.PortableServer.POA poa, byte[] obj_id)
	{
		return ids;
	}
}
